function f = evaluate_objective(name, x, nObj, nVar)
V=nVar;
switch name
    case{'ICF1'}
%         f = [];
        for i = 3:2:V
            ma = max(0.45*abs(sin(0.5*i*pi)),0.5+0.45*abs(sin(0.5*i*pi)));
            mi = min(0.45*abs(sin(0.5*i*pi)),0.5+0.45*abs(sin(0.5*i*pi)));
            c(i) = infsup(mi,ma);
            g1 = g1 + (x(i)*c(i)-sin(0.5*pi*c1*x(1)))^2;
        end
        for o = 2:2:V
            ma = max(0.45*abs(sin(0.5*o*pi)),0.5+0.45*abs(sin(0.5*o*pi)));
            mi = min(0.45*abs(sin(0.5*o*pi)),0.5+0.45*abs(sin(0.5*o*pi)));
            c(o) = infsup(mi,ma);
        	g2 = g2 + (x(o)*c(o)-cos(0.5*pi*c(o)*x(o)))^2;
        end
        g1 = 1 + sum_x;
        
        f(1) = inf(infsup(0.9,1)*x(1));
        f(2) = sup(infsup(0.9,1)*x(1));
        f(3) = inf(g1*(1-(0.85*f(1))./g1));
        f(4) = sup(g1*(1-(0.85*f(1))./g1));

    case {'ZDT1'}
        f = [];
        sum_x = 0;
        g = [];
        for i = 2 : V 
            sum_x = sum_x + x(i)^2;
        end
        g_x = 1+9*sum_x/(V-1);
        g(1) = x(1);
        g(2) = g_x*(1-sqrt(g(1)/g_x));
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
    case {'ZDT2'}
        f = [];
        g = [];
        sum_x = 0;
        for i = 2 : V   
            sum_x = sum_x + x(i)^2;
        end	
        g_x = 1+9*sum_x/(V-1);
        g(1) = x(1);
        g(2) = g_x*(1-(g(1)/g_x)^2);
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
    case {'ZDT3'}
        f = [];
        g = [];
        sum_x = 0;
        for i = 2 : V  
            sum_x = sum_x + x(i)^2;
        end
        g_x = 1+9*sum_x/(V-1);
        g(1) = x(1);
        g(2) = g_x*(1-sqrt(g(1)/g_x)-(g(1)/g_x)*sin(10*pi*g(1)));
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
    case 'ZDT4'
        f = [];
        sum_x = 0;
        g = [];
        for i = 2 : V
            sum_x = sum_x + x(i)^2-10*cos(4*pi*x(i));
        end
        g_x = 1+10*(V-1)+sum_x;
        g(1) = x(1);
        g(2) = g_x*(1-sqrt(g(1)/g_x));
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
    case 'F1'
        summ=0;
        for i=2:nVar
            summ=summ+x(i)^2;
        end
        f=[];
        g_xm=1+9*summ/(nVar-1);
        g(1)=x(1);
        g(2)=g_xm*(1-sqrt(g(1)/g_xm))^(3+0.1);
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
    case 'F2'
        g1 = 2:9;
        g2 = 10:15;
        g_xm=1+sum(x(g1).^2);
        g(1)=x(1);
        Ht=0.25+0.45*abs(sin(0.5*pi));
        H2t=(Ht+sum((x(g2)-Ht).^2))^(-1);
        h=1-(g(1)/g_xm)^(H2t);
        g(2)=g_xm*h;       
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
    case 'F3'
        Ft=10^(2*sin(0.5*pi));
        g(1)=x(1).^Ft;
        Gt=abs(sin(0.5*pi));
        g_xm=1+Gt+sum((x(2:nVar)-Gt).^2);
        h=1-sqrt(g(1)./g_xm);
        g(2)=g_xm*h;
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
    case 'F4'
        g1 = 2:9;
        g2 = 10:15;
        Gt=0.25+0.45*abs(sin(0.5*pi));
        g(1)=(x(1)-Gt)^2  +sum(x(g1).^2)+sum((x(g2)-Gt).^2);
        g(2)=(x(1)-Gt-2)^2+sum(x(g1).^2)+sum((x(g2)-Gt).^2);
        
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
    case 'F5'
        H = 0.75*sin(0.5*pi)+1.25;
        g(1) = x(1);
        gg = 1 + 9*sum((x(2:nVar)).^2)./(nVar-1);
        h = 1 - (sqrt(g(1)./gg)).^H-(g(1)./gg).^H.*sin(10*pi*g(1));
        g(2) = gg.*h;      
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
    case 'F6'
        g1 = 2:9;
        g2 = 10:15;
        g11=sum((x(g1)-0.5).^2);
        g22=sum((x(g2)).^2);
        g_xm=g11+g22;
        g(1)=(1+g_xm)*cos(x(1)*(pi/2));
        g(2)=(1+g_xm)*sin(x(1)*(pi/2));
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
    case 'DTLZ1'
        f = [];
        sum_x = 0;
        g = [];
        for i = 3 : V
            sum_x = sum_x + (x(i)-0.5)^2-cos(20*pi*(x(i)-0.5));
        end
        sum_x=sum_x/(V-3+1);
        g_x = 100*(V-3+1+sum_x)/(100*(V-3+1));
        g(1) = (1 + g_x)*x(1)*x(2)/2;
        g(2) = (1 + g_x)*x(1)*(1-x(2))/2;
        g(3) = (1 + g_x)*(1-x(1))/2;              
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(5) = min(g(3),g(3)+sin(40*pi*sum(x))/4);
        f(6) = max(g(3),g(3)+sin(40*pi*sum(x))/4);
    case 'DTLZ2'
        f = [];
        g_x = 0;
        g = [];
        for i = 3 : V
            g_x = g_x + (x(i) - 0.5)^2;
        end
        g_x=g_x/(V-3+1);
        g(1) = (1 + g_x)*cos(0.5*pi*x(1))*cos(0.5*pi*x(2));
        g(2) = (1 + g_x)*cos(0.5*pi*x(1))*sin(0.5*pi*x(2));
        g(3) = (1 + g_x)*sin(0.5*pi*x(1));                 
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(5) = min(g(3),g(3)+sin(40*pi*sum(x))/4);
        f(6) = max(g(3),g(3)+sin(40*pi*sum(x))/4);
    case 'DTLZ5'
        f = [];
        g_x = 0;
        g = [];
        for i = 3 : V
            g_x = g_x + (x(i) - 0.5)^2;
        end
        sum_x = g_x;
        g_x=g_x/(V-3+1);   
        for i = 1 : 2
            theta(i) = pi*(1+2*sum_x*x(i))/(4*(1+sum_x)); 
        end
        g(1) = (1 + g_x)*cos(theta(1)*pi/2)*cos(theta(2)*pi/2);
        g(2) = (1 + g_x)*cos(theta(1)*pi/2)*sin(theta(2)*pi/2);
        g(3) = (1 + g_x)*sin(theta(1)*pi/2);
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(5) = min(g(3),g(3)+sin(40*pi*sum(x))/4);
        f(6) = max(g(3),g(3)+sin(40*pi*sum(x))/4);
    case 'DTLZ7'
        f = [];
        g_x = 0;
        g = [];
        sum_x = 0;
        for i = 3:V
            g_x = g_x + 9*x(i)/(V-3+1);
        end 
        g_x = g_x + 1;
        g(1) = x(1);
        g(2) = x(2);        
        for i = 1:2
            sum_x = sum_x + (g(i)*(1+sin(3*pi*g(i)))/(1+(V-3+1)));
        end
        
        h = 3 - sum_x;
        g(3) = (1+g_x)*h;
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(5) = min(g(3),g(3)+sin(40*pi*sum(x))/4);
        f(6) = max(g(3),g(3)+sin(40*pi*sum(x))/4);
    case 'WFG1'
        PopDec = x;
        [N,D] = size(PopDec);
        M = 3;K = 2;L = D-K;D=1;S = 2:2:2*M;A = ones(1,M-1);
        z01 = PopDec./repmat(2:2:size(PopDec,2)*2,N,1);
        t1 = zeros(N,K+L);
        t1(:,1:K)     = z01(:,1:K);
        t1(:,K+1:end) = s_linear(z01(:,K+1:end),0.35);
        t2 = zeros(N,K+L);
        t2(:,1:K)     = t1(:,1:K);
        t2(:,K+1:end) = b_flat(t1(:,K+1:end),0.8,0.75,0.85);
        t3 = zeros(N,K+L);
        t3 = b_poly(t2,0.02);
        t4 = zeros(N,M);
        for i = 1 : M-1
            t4(:,i) = r_sum(t3(:,(i-1)*K/(M-1)+1:i*K/(M-1)),2*((i-1)*K/(M-1)+1):2:2*i*K/(M-1));
        end
        t4(:,M) = r_sum(t3(:,K+1:K+L),2*(K+1):2:2*(K+L));
        x = zeros(N,M);
        for i = 1 : M-1
            x(:,i) = max(t4(:,M),A(i)).*(t4(:,i)-0.5)+0.5;
        end
         x(:,M) = t4(:,M);
         h      = convex(x);
         h(:,M) = mixed(x);
         g = repmat(D*x(:,M),1,M) + repmat(S,N,1).*h;
         f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
         f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
         f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
         f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
         f(5) = min(g(3),g(3)+sin(40*pi*sum(x))/4);
         f(6) = max(g(3),g(3)+sin(40*pi*sum(x))/4);
    case 'WFG2'
         PopDec = x;
         [N,D] = size(PopDec);
         M = 3;
         K = 2;
         L = D - K;
         D = 1;
         S = 2 : 2 : 2*M;
         A = ones(1,M-1);
         z01 = PopDec./repmat(2:2:size(PopDec,2)*2,N,1);
         t1 = zeros(N,K+L);
         t1(:,1:K)     = z01(:,1:K);
         t1(:,K+1:end) = s_linear(z01(:,K+1:end),0.35);
         t2 = zeros(N,K+L/2);
         t2(:,1:K) = t1(:,1:K);
         t2(:,K+1:K+L/2) = (t1(:,K+1:2:end) + t1(:,K+2:2:end) + 2*abs(t1(:,K+1:2:end)-t1(:,K+2:2:end)))/3; 
         t3 = zeros(N,M);
         for i = 1 : M-1
             t3(:,i) = r_sum(t2(:,(i-1)*K/(M-1)+1:i*K/(M-1)),ones(1,K/(M-1)));
         end
         t3(:,M) = r_sum(t2(:,K+1:K+L/2),ones(1,L/2));
         x = zeros(N,M);
         for i = 1 : M-1
             x(:,i) = max(t3(:,M),A(:,i)).*(t3(:,i)-0.5)+0.5;
         end
         x(:,M) = t3(:,M);
         h      = convex(x);
         h(:,M) = disc(x);
         g = repmat(D*x(:,M),1,M) + repmat(S,N,1).*h;
         f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
         f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
         f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
         f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
         f(5) = min(g(3),g(3)+sin(40*pi*sum(x))/4);
         f(6) = max(g(3),g(3)+sin(40*pi*sum(x))/4);
    case 'WFG3'
        PopDec = x;
        [N,D] = size(PopDec);
        M = 3;
        K = 2;
        L = D - K;
        D = 1;
        S = 2 : 2 : 2*M;
        A = [1,zeros(1,M-2)];
        z01 = PopDec./repmat(2:2:size(PopDec,2)*2,N,1);
        t1 = zeros(N,K+L);
        t1(:,1:K)     = z01(:,1:K);
        t1(:,K+1:end) = s_linear(z01(:,K+1:end),0.35);
        t2 = zeros(N,K+L/2);
        t2(:,1:K) = t1(:,1:K);
        t2(:,K+1:K+L/2) = (t1(:,K+1:2:end) + t1(:,K+2:2:end) + 2*abs(t1(:,K+1:2:end)-t1(:,K+2:2:end)))/3;
        t3 = zeros(N,M);
        for i = 1 : M-1
            t3(:,i) = r_sum(t2(:,(i-1)*K/(M-1)+1:i*K/(M-1)),ones(1,K/(M-1)));
         end
         t3(:,M) = r_sum(t2(:,K+1:K+L/2),ones(1,L/2));
         x = zeros(N,M);
         for i = 1 : M-1
             x(:,i) = max(t3(:,M),A(:,i)).*(t3(:,i)-0.5)+0.5;
         end
         x(:,M) = t3(:,M);
         h      = linear1(x);
         g = repmat(D*x(:,M),1,M) + repmat(S,N,1).*h;
         f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
         f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
         f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
         f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
         f(5) = min(g(3),g(3)+sin(40*pi*sum(x))/4);
         f(6) = max(g(3),g(3)+sin(40*pi*sum(x))/4);
    case 'WFG4'
        PopDec = x;
        [N,D] = size(PopDec);
        M = 3;
        K = 2;
        L = D - K;
        D = 1;
        S = 2 : 2 : 2*M;
        A = ones(1,M-1);
        z01 = PopDec./repmat(2:2:size(PopDec,2)*2,N,1);
        t1 = zeros(N,K+L);
        t1 = s_multi(z01,30,10,0.35);
        t2 = zeros(N,M);
        for i = 1 : M-1
            t2(:,i) = r_sum(t1(:,(i-1)*K/(M-1)+1:i*K/(M-1)),ones(1,K/(M-1)));
        end
        t2(:,M) = r_sum(t1(:,K+1:K+L),ones(1,L));
        x = zeros(N,M);
        for i = 1 : M-1
            x(:,i) = max(t2(:,M),A(:,i)).*(t2(:,i)-0.5)+0.5;
        end
        x(:,M) = t2(:,M);
        h = concave(x);
        g = repmat(D*x(:,M),1,M) + repmat(S,N,1).*h;
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(5) = min(g(3),g(3)+sin(40*pi*sum(x))/4);
        f(6) = max(g(3),g(3)+sin(40*pi*sum(x))/4);
    case 'IMOP1'
        a1 = 0.05;
        K = 5;
        PopDec = x;
        y1 = mean(PopDec(:,1:K),2).^a1;
        g1  = sum((PopDec(:,K+1:end)-0.5).^2,2);
        g(:,1) = g1 + cos(y1*pi/2).^8;
        g(:,2) = g1 + sin(y1*pi/2).^8;
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
    case 'IMOP2'
        a1 = 0.05;
        K = 5;
        PopDec = x;
        y1 = mean(PopDec(:,1:K),2).^a1;
        g1  = sum((PopDec(:,K+1:end)-0.5).^2,2);
        g(:,1) = g1 + cos(y1*pi/2).^0.5;
        g(:,2) = g1 + sin(y1*pi/2).^0.5;
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
    case 'IMOP3'
        a1 = 0.05;
        K = 5;
        PopDec = x;
        y1 = mean(PopDec(:,1:K),2).^a1;
        g1  = sum((PopDec(:,K+1:end)-0.5).^2,2);
        g(:,1) = g1 + (1+cos(y1*pi*10)/5-y1);
        g(:,2) = g1 + y1;
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
    case 'IMOP4'
        a1 = 0.05;
        K = 5;
        PopDec = x;
        y1 = mean(PopDec(:,1:K),2).^a1;
        g1  = sum((PopDec(:,K+1:end)-0.5).^2,2);
        g(:,1) = (1+g1).*(y1);
        g(:,2) = (1+g1).*(y1+sin(10*pi*y1)/10);
        g(:,3) = (1+g1).*(1-y1);
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(5) = min(g(3),g(3)+sin(40*pi*sum(x))/4);
        f(6) = max(g(3),g(3)+sin(40*pi*sum(x))/4);
    case 'IMOP5'
        a1 = 0.05;  % Parameter a1
        a2 = 10;    % Parameter a2
        K  = 5;  
        PopDec = x;
        y1 = mean(PopDec(:,1:2:K),2).^a1;
        y2 = mean(PopDec(:,2:2:K),2).^a2;
        g1  = sum((PopDec(:,K+1:end)-0.5).^2,2);
        PopObj(:,1) = 0.4*cos(pi*ceil(y1*8)/4) + 0.1*y2.*cos(16*pi*y1);
        PopObj(:,2) = 0.4*sin(pi*ceil(y1*8)/4) + 0.1*y2.*sin(16*pi*y1);
        PopObj(:,3) = 0.5 - sum(PopObj(:,1:2),2);
        g = PopObj + repmat(g1,1,3);
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(5) = min(g(3),g(3)+sin(40*pi*sum(x))/4);
        f(6) = max(g(3),g(3)+sin(40*pi*sum(x))/4);
    case 'IMOP6'
        a1 = 0.05;  % Parameter a1
        a2 = 10;    % Parameter a2
        K  = 5;  
        PopDec = x;
        y1 = mean(PopDec(:,1:2:K),2).^a1;
        y2 = mean(PopDec(:,2:2:K),2).^a2;
        g1  = sum((PopDec(:,K+1:end)-0.5).^2,2);
        r  = max(0,min(sin(3*pi*y1).^2,sin(3*pi*y2).^2)-0.05);
        g(:,1) = (1+g1).*y1 + ceil(r);
        g(:,2) = (1+g1).*y2 + ceil(r);
        g(:,3) = (0.5+g1).*(2-y1-y2) + ceil(r);
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(5) = min(g(3),g(3)+sin(40*pi*sum(x))/4);
        f(6) = max(g(3),g(3)+sin(40*pi*sum(x))/4);
    case 'IMOP7'
        a1 = 0.05;
        a2 = 10;
        K  = 5;  
        PopDec = x;
        y1 = mean(PopDec(:,1:2:K),2).^a1;
        y2 = mean(PopDec(:,2:2:K),2).^a2;
        g1  = sum((PopDec(:,K+1:end)-0.5).^2,2);
        PopObj(:,1) = (1+g1).*cos(y1*pi/2).*cos(y2*pi/2);
        PopObj(:,2) = (1+g1).*cos(y1*pi/2).*sin(y2*pi/2);
        PopObj(:,3) = (1+g1).*sin(y1*pi/2);
        r = min(min(abs(PopObj(:,1)-PopObj(:,2)),abs(PopObj(:,2)-PopObj(:,3))),abs(PopObj(:,3)-PopObj(:,1)));
        g = PopObj + repmat(10*max(0,r-0.1),1,3);
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(5) = min(g(3),g(3)+sin(40*pi*sum(x))/4);
        f(6) = max(g(3),g(3)+sin(40*pi*sum(x))/4);
    case 'IMOP8'
        a1 = 0.05;
        a2 = 10;
        K  = 5;  
        PopDec = x;
        y1 = mean(PopDec(:,1:2:K),2).^a1;
        y2 = mean(PopDec(:,2:2:K),2).^a2;
        g1  = sum((PopDec(:,K+1:end)-0.5).^2,2);
        PopObj(:,1) = y1;
        PopObj(:,2) = y2;
        PopObj(:,3) = (1+g1).*(3-sum(PopObj(:,1:2)./(1+repmat(g1,1,2)).*(1+sin(19*pi.*PopObj(:,1:2))),2));
        g = PopObj;
        f(1) = min(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(2) = max(g(1),g(1)+sin(10*pi*sum(x))/4);
        f(3) = min(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(4) = max(g(2),g(2)+sin(20*pi*sum(x))/4);
        f(5) = min(g(3),g(3)+sin(40*pi*sum(x))/4);
        f(6) = max(g(3),g(3)+sin(40*pi*sum(x))/4);
    if length(f) ~= nObj
       error('The number of decision variables does not match you previous input. Kindly check your objective function');
    end
end
